<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org"
      xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity4">
<head th:include="base/head.html::static">
<title>假条记录</title>
</head>
  
<body>
<div class="lyear-layout-web">
  <div class="lyear-layout-container">

    <!--左侧导航-->
    <aside class="lyear-layout-sidebar" th:include="base/base.html::left"></aside>

    <!--头部信息-->
    <header class="lyear-layout-header" th:include="base/base.html::header"></header>
    
    <!--页面主要内容-->
    <main class="lyear-layout-content">
      
      <div class="container-fluid">
        
        <div class="row">
          <div class="col-lg-12">
            <div class="card">
              <div class="card-body">
                
                <div class="table-responsive">
                  <table class="table table-bordered">
                    <thead>
                      <tr>
                        <th>编号</th>
                        <th>课程</th>
                        <th>申请时间</th>
                        <th>审核通过时间</th>
                        <th>审核老师</th>
                        <th>状态</th>
                        <th>操作</th>
                      </tr>
                    </thead>
                    <tbody>
                      <tr th:each="leaveNote:${result.records}">
                        <td th:text="${leaveNote.id}">1</td>
                        <td th:text="${leaveNote.courseName}">ssm企业级开发</td>
                        <td th:text="${#dates.format(leaveNote.timeStudent,'yyyy-MM-dd HH:mm:ss')}">2019-2-2 12:23</td>
                        <td th:text="${#dates.format(leaveNote.timeTeacher,'yyyy-MM-dd HH:mm:ss')}">2019-2-2 12:23</td>
                        <td th:text="${leaveNote.teacherName}">周胜</td>
                        <td th:if="${leaveNote.state == 1}"><font class="text-success">审核通过</font></td>
                        <td th:if="${leaveNote.state == 0}"><font class="text-warning">未审核</font></td>
                        <td th:if="${leaveNote.state == -1}"><font class="text-danger">审核未通过</font></td>
                        <td>
                          <div class="btn-group">
                            <a class="btn btn-xs btn-default" th:href="${'/leave-note/Onelog/'+leaveNote.id}"
                               title="查看" data-toggle="tooltip">
                              <i class="mdi mdi-code-greater-than"></i>
                            </a>
                          </div>
                        </td>
                      </tr>
                    </tbody>
                  </table>
                </div>
                <ul class="pagination">
                  <li th:class="${result.current == 1 } ? disabled: ''"><a th:href="@{/leave-note/log/1}">«</a></li>
                  <li th:if="${result.current-6 > 0 and result.current+1 > maxPage}"><a th:href="${'/leave-note/log/'+ (result.current-6)}" th:text="${result.current-6}">当前页的前6页</a></li>
                  <li th:if="${result.current-5 > 0 and result.current+2 > maxPage}"><a th:href="${'/leave-note/log/'+ (result.current-5)}" th:text="${result.current-5}">当前页的前5页</a></li>
                  <li th:if="${result.current-4 > 0 and result.current+3 > maxPage}"><a th:href="${'/leave-note/log/'+ (result.current-4)}" th:text="${result.current-4}">当前页的前4页</a></li>
                  <li th:if="${result.current-3 > 0}"><a th:href="${'/leave-note/log/'+ (result.current-3)}" th:text="${result.current-3}">当前页的前3页</a></li>
                  <li th:if="${result.current-2 > 0}"><a th:href="${'/leave-note/log/'+ (result.current-2)}" th:text="${result.current-2}">当前页的前2页</a></li>
                  <li th:if="${result.current-1 > 0}"><a th:href="${'/leave-note/log/'+ (result.current-1)}" th:text="${result.current-1}">当前页的前1页</a></li>
                  <li class="active"><a th:text="${result.current}" href="#">1</a></li>
                  <li th:if="${result.current+1 <= maxPage}"><a th:href="${'/leave-note/log/'+ (result.current+1)}" th:text="${result.current+1}">当前页的后1页</a></li>
                  <li th:if="${result.current+2 <= maxPage}"><a th:href="${'/leave-note/log/'+ (result.current+2)}" th:text="${result.current+2}">当前页的后2页</a></li>
                  <li th:if="${result.current+3 <= maxPage}"><a th:href="${'/leave-note/log/'+ (result.current+3)}" th:text="${result.current+3}">当前页的后3页</a></li>
                  <li th:if="${result.current+4 <= maxPage and result.current-3 <= 0}"><a th:href="${'/leave-note/log/'+ (result.current+4)}" th:text="${result.current+4}">当前页的后4页</a></li>
                  <li th:if="${result.current+5 <= maxPage and result.current-2 <= 0}"><a th:href="${'/leave-note/log/'+ (result.current+5)}" th:text="${result.current+5}">当前页的后5页</a></li>
                  <li th:if="${result.current+6 <= maxPage and result.current-1 <= 0}"><a th:href="${'/leave-note/log/'+ (result.current+6)}" th:text="${result.current+6}">当前页的后6页</a></li>
                  <li th:class="${result.current == maxPage } ? disabled: ''"><a th:href="${'/leave-note/log/'+ maxPage}">»</a></li>
                </ul>
       
              </div>
            </div>
          </div>
          
        </div>
        
      </div>
      
    </main>
    <!--End 页面主要内容-->
  </div>
</div>

</body>
</html>